package com.biz.primus.base.elasticsearch.entities;

import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldIndex;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.io.Serializable;

public class PropertyEntity implements Serializable {

    /**
     * 存储扩展属性唯一的key  eg. baijiu_weight
     */
    @Field(type = FieldType.String, store = true,index = FieldIndex.not_analyzed)
    private String name;

    /**
     * 存储值  eg. 12g
     */
    @Field(type = FieldType.String, store = true,index = FieldIndex.not_analyzed)
    private String value;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getValue() {
        return value;
    }

    public void setValue(String value) {
        this.value = value;
    }

    public PropertyEntity(String name, String value) {
        this.name = name;
        this.value = value;
    }

    public PropertyEntity() {
    }
}
